package com.wn.ticket.service.impl;

import com.wn.ticket.entity.Notice;
import com.wn.ticket.mapper.HotSearchMapper;
import com.wn.ticket.mapper.NoticeMapper;
import com.wn.ticket.service.NoticeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class NoticeServiceImpl implements NoticeService {

    @Autowired
    private NoticeMapper noticeMapper;

    @Override
    public void add(Notice notice) {
        noticeMapper.insert(notice);
    }

    @Override
    public void del(int id) {
        noticeMapper.delete(id);
    }

    @Override
    public List<Notice> getAll() {
        return noticeMapper.getAll();
    }
}
